package com.liam.apppush.client.getui;


import com.gexin.rp.sdk.base.IPushResult;
import com.gexin.rp.sdk.base.IQueryResult;
import com.gexin.rp.sdk.http.IGtPush;
import com.liam.apppush.config.GeTuiConfig;
import lombok.extern.slf4j.Slf4j;
import org.springframework.stereotype.Component;

import java.util.List;

@Deprecated
@Slf4j
@Component
public class GeTuiUserClient extends GeTuiConfig {


    /**
     * 对指定用户设置tag属性
     * @param cid
     * @param tags
     */
    public void setTags(String cid, List<String> tags) {
        IQueryResult ret = getPush().setClientTag(appId, cid, tags);
        System.out.println(ret.getResponse().toString());
    }

    /**
     * 获取指定用户的tag属性
     */
    public  void getUserTags (String cid) {
        IPushResult ret = getPush().getUserTags(appId, cid);
        System.out.println(ret.getResponse().toString());
    }

    /**
     * 批量获取用户的tag属性
     */
    public  void getUserListTags() {
//        List<String> list = new ArrayList<String>(2);
//        list.add(CID);
//        list.add(CID_2);
//        IPushResult ret = getPush().getUserListTags(APPID, list);
//        System.out.println(ret.getResponse().toString());
    }

}
